package Level02_one;

public class Student extends Person {
    private double score;

    void eat(){
        System.out.println("成绩为 "+getScore()+" 分的 "+super.getAge()+" 岁的"+super.getName()+"学生在吃学生餐");
    }
    void study(){
        System.out.println("成绩为 "+getScore()+"分的 "+super.getAge()+" 岁的"+super.getName()+"学生在学习");
    }

    public Student(int age, String name, double score) {
        super(age, name);
        this.score = score;
    }

    public Student() {
        this.score = score;
    }

    public double getScore() {
        return score;
    }

    public void setScore(double score) {
        this.score = score;
    }
}
